For many applications, it is advantageous to store their associated data in both a database and a filesystem. For example, many applications will have their smaller and more structured data stored in a database and will have their larger and less structured data stored in a filesystem. Such larger and less structured data may include, for example, pictures, photographs, other video content, audio content, and the like. When data is distributed between a database and a filesystem, the data may be logically organized in the database (e.g. as a column in a data table) and physically stored in the filesystem. There are a number of reasons that this distribution of data between a database and a filesystem is advantageous. For example, reading and writing large unstructured data generally cannot be performed as efficiently with a database as with a filesystem. Also, the size of some data collections may simply exceed what a database server can accommodate.
One of the services that databases provide is that of a transaction. A transaction pertains to changes made to one or more resources. A transaction provides for atomicity, consistency, isolation and durability. The term atomicity refers to the ability to make changes such that when a transaction is completed, all changes within the transaction are either committed or not committed. If the transaction is not committed, then all changes within the transaction may be rolled back or one or more conflict resolution techniques may be employed to resolve conflicts between the changes within the transaction and other changes.
Unlike databases, filesystems traditionally have not offered transactional services. Thus, a number of problems may arise when an application attempts to change its data that is stored in both a database and a filesystem. For example, certain changes may be made to documents stored in the filesystem without making corresponding changes to information stored in the database. In this scenario, the application is burdened with the tasks of detecting and fixing these inconsistencies. Accordingly, there is a need in the art for systems and methods for coordinating transactions involving data that is stored in both a database and a filesystem.